package personal.model.service;

import java.sql.SQLException;
import java.util.List;

import personal.model.dao.CodeManagementDao;
import personal.model.vo.AdminVO;
import personal.model.vo.DeptVO;
import personal.model.vo.GradeVO;

public class CodeManagementServiceImpl implements CodeManagementService{
	private CodeManagementDao codeManagementDao;
	@Override
	public void setCodeManagementDao(CodeManagementDao codeManagementDao) {
		this.codeManagementDao=codeManagementDao;
	}
	@Override
	public void insertDeptCode(DeptVO deptVO) throws SQLException {
		codeManagementDao.insertDeptCode(deptVO);
	}
	@Override
	public void insertAdminCode(AdminVO adminVO) throws SQLException {
		codeManagementDao.insertAdminCode(adminVO);
	}
	@Override
	public void insertGradeCode(GradeVO gradeVO) throws SQLException {
		codeManagementDao.insertGradeCode(gradeVO);
	}
	@Override
	public List<DeptVO> selectDeptCode() throws SQLException {
		return codeManagementDao.selectDeptCode();
	}
	@Override
	public List<AdminVO> selectAdminCode() throws SQLException {
		return codeManagementDao.selectAdminCode();
	}
	@Override
	public List<GradeVO> selectGradeCode() throws SQLException {
		return codeManagementDao.selectGradeCode();
	}
	@Override
	public void updateDeptCode(DeptVO deptVO) throws SQLException {
		codeManagementDao.updateDeptCode(deptVO);
	}
	@Override
	public void updateAdminCode(AdminVO adminVO) throws SQLException {
		codeManagementDao.updateAdminCode(adminVO);
	}
	@Override
	public void updateGradeCode(GradeVO gradeVO) throws SQLException {
		codeManagementDao.updateGradeCode(gradeVO);
	}
	@Override
	public void deleteDeptCode(int deptNo) throws SQLException {
		codeManagementDao.deleteDeptCode(deptNo);
	}
	@Override
	public void deleteAdminCode(int adminNo) throws SQLException {
		codeManagementDao.deleteAdminCode(adminNo);
	}
	@Override
	public void deleteGradeCode(int gradeNo) throws SQLException {
		codeManagementDao.deleteGradeCode(gradeNo);
	}
	@Override
	public DeptVO selectDeptCodeByDeptNo(int deptNo) throws SQLException {
		return codeManagementDao.selectDeptCodeByDeptNo(deptNo);
	}
	@Override
	public AdminVO selectAdminCodeByAdminNo(int adminNo) throws SQLException {
		return codeManagementDao.selectAdminCodeByAdminNo(adminNo);
	}
	@Override
	public GradeVO selectGradeCodeByGradeNo(int gradeNo) throws SQLException {
		return codeManagementDao.selectGradeCodeByGradeNo(gradeNo);
	}
}